var http = require("http");
var querystring = require("querystring");

var app = http.createServer(function (request, response) {

    response.setHeader('Content-type','text/plain');
    response.setHeader('Access-Control-Allow-Origin','*');

    var postData = "";
    request.on('data', function (chunk) {
        postData += chunk;
    });
    request.on("end", function () {
        // 解析参数
        postData = querystring.parse(postData);
        console.log(postData);

    });
    response.end("hello world\n");


}).listen(8889, function () {
    console.log('Server running at http://127.0.0.1:8889/');
});










https://gitee.com/Chendt_Study/DEMO.githttps://gitee.com/Chendt_Study/DEMO.git


